import sevoes from "@/util/Http";
import Qs from "qs";
function adminInquire(data) {
  //管理员查询
  return sevoes({
    method: "get",
    params: {
      _gp: "admin",
      _mt: "list",
      ...data,
    },
  });
}

function adminAddition(data) {
  //管理员添加
  return sevoes({
    method: "post",
    data: Qs.stringify({
      _gp: "admin",
      _mt: "create",
      ...data,
    }),
  })
}

function adminCompile(data) {
  //编辑
  return sevoes({
    method: "post",
    data: Qs.stringify({
      _gp: "admin",
      _mt: "update",
      ...data,
    }),
  })
}

function adminDelete(data) { 
  //删除
  return sevoes({
    method: "post",
    data: Qs.stringify({
      _gp: "admin",
      _mt: "delete",
      ...data,
    }),
  })
}

export default {
  adminInquire,
  adminAddition,
  adminCompile,
  adminDelete,
}